#ifndef PROJECTILE_H
#define PROJECTILE_H

class Cannon;

class Projectile : public Object
{
    public:
        Projectile();
        ~Projectile();
        void show_object(Cannon* cannon);
        void move_object(Cannon* cannon);
        void clear_surface();
        bool getIsAirborne();
        bool isShot();
        bool isFalling() {return falling;}
        void shootProjectile(float rot, Cannon* cannon);
        float getTrueX() {return trueX;}
        float getTrueY() {return trueY;}
        void resetGame();
    protected:
    private:
        bool isAirborne;
        bool falling;
        bool shot;
        float trueX;
        float trueY;
        float angle;
        float rotation;
        float gravity;
        float cannonPower;
        int state;
        double time;

        SDL_Surface* firstProjectile = NULL;
        SDL_Surface* rotatingProjectile = NULL;
};

#endif // PROJECTILE_H
